import java.util.Arrays;

/**
 * @ClassName LC1464
 * @Author ykx
 * @Date 2024/7/2 22:23
 * @Version 1.0
 */
public class LC1464 {
    public static void main(String[] args) {

    }

    public int maxProduct(int[] nums) {
        Arrays.sort(nums);
        return (nums[nums.length - 1] - 1) * (nums[nums.length - 2] - 1);
    }

}
